load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library")

go_library(
    name = "roachprod_lib",
    srcs = [
        "bash_completion.go",
        "flags.go",
        "main.go",
    ],
    importpath = "github.com/cockroachdb/cockroach/pkg/cmd/roachprod",
    visibility = ["//visibility:private"],
    deps = [
        "//pkg/build",
        "//pkg/cmd/roachprod/grafana",
        "//pkg/cmd/roachprod/update",
        "//pkg/roachprod",
        "//pkg/roachprod/cloud",
        "//pkg/roachprod/config",
        "//pkg/roachprod/errors",
        "//pkg/roachprod/fluentbit",
        "//pkg/roachprod/install",
        "//pkg/roachprod/opentelemetry",
        "//pkg/roachprod/roachprodutil",
        "//pkg/roachprod/ssh",
        "//pkg/roachprod/ui",
        "//pkg/roachprod/vm",
        "//pkg/roachprod/vm/gce",
        "//pkg/util/envutil",
        "//pkg/util/flagutil",
        "//pkg/util/timeutil",
        "@com_github_cockroachdb_errors//:errors",
        "@com_github_fatih_color//:color",
        "@com_github_spf13_cobra//:cobra",
        "@org_golang_x_crypto//ssh",
        "@org_golang_x_exp//maps",
        "@org_golang_x_term//:term",
        "@org_golang_x_text//language",
        "@org_golang_x_text//message",
    ],
)

go_binary(
    name = "roachprod",
    embed = [":roachprod_lib"],
    exec_properties = {"Pool": "large"},
    visibility = ["//visibility:public"],
)
